package com.demo;

import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.scheduling.annotation.EnableAsync;
import org.springframework.scheduling.annotation.EnableScheduling;
import org.springframework.session.data.redis.config.annotation.web.http.EnableRedisHttpSession;
import org.springframework.transaction.annotation.EnableTransactionManagement;

@SpringBootApplication(scanBasePackages = {"com.demo"})
@EnableTransactionManagement //事务
@EnableScheduling //定时任务
@EnableAsync //异步调用
@MapperScan(basePackages = {"com.demo.mappers"})
@EnableRedisHttpSession(maxInactiveIntervalInSeconds = 2400, redisNamespace = "demo:session")
public class DemoApplication {
    public static void main(String[] args) {
        SpringApplication.run(DemoApplication.class, args);
    }

}
